from selenium.webdriver.common.by import By

from base import Base
class Page(Base):
    def dianjigouwuche(self):#点击购物车
        loc=(By.ID,'com.kongfz.app:id/ll_nav4')
        ele=self.find_ele(loc)
        return ele
    def dainjisousuoanniu(self):
        loc=(By.ANDROID_UIAUTOMATOR,'new UiSelector().resourceId("com.kongfz.app:id/icon_font_search")')
        ele=self.find_ele(loc)
        return ele
    def diansousuokuang(self):
        loc=(By.CLASS_NAME,'android.widget.EditText')
        ele=self.find_ele(loc)
        return ele
    def fanhui(self):
        loc=(By.XPATH,'//android.widget.TextView[@resource-id="com.kongfz.app:id/tv_back"]')
        ele=self.find_ele(loc)
        return ele
    def dianguanli(self):
        loc=(By.XPATH,'//android.widget.TextView[@resource-id="com.kongfz.app:id/tv_manage"]')
        ele=self.find_ele(loc)
        return ele
    # def dianshanchu(self):
    #     loc=(By.ASSSDAER_AILITY,'new UiSelector().resourceId("com.kongfz.app:id/icon_font_search")')
    #     ele=self.find_ele(loc)
    #     return ele
    def quanbu(self):#断言
        loc=(By.XPATH,'//android.widget.TextView[@resource-id="com.kongfz.app:id/tv_char_all"]')
        ele=self.find_ele(loc)
        return ele